var status = -1;
var selectionLog = [];

function start() {
    action(1, 0, 0)
}

function action(d, c, b) {
    if (status == 0 && d == 0) {
        im.dispose();
        return
    }(d == 1) ? status++ : status--;
    selectionLog[status] = b;
    var a = -1;
    if (status <= a++) {
        im.dispose()
    } else {
        if (status === a++) {
            im.dispose();
            if (im.getzhizunvip() == 2) {
                im.openNpc(0, "剧烈的风暴卷轴箱子_至尊版")
            } else {
                im.playerMessage(-1, "奇怪的箱子，切换到至尊版试试。")
            }
        }
    }
};